
<!DOCTYPE html>
<html xmlns:th="http://www.thymeleaf.org">
<head>
	<title>菜单管理</title>
	<meta name="renderer" content="webkit">
	<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
	<meta name="viewport" content="width=device-width, initial-scale=1.0, minimum-scale=1.0, maximum-scale=1.0, user-scalable=0">
	<link rel="stylesheet" th:href="@{/layuiadmin/layui/css/layui.css}" media="all">
	<link rel="stylesheet" th:href="@{/layuiadmin/style/admin.css}" media="all">
	<style>
		.layui-table-cell {
			height: auto;
			line-height: 30px;
		}
	</style>
</head>
<body>

	<script th:src="@{/layuiadmin/layui/layui.js}"></script>

	<div class="layui-container" style="position:absolute; top:25%;left: 25%;">
		<blockquote class="layui-elem-quote">填写完整身份证号点击提交，如果添加失败后请联系额QA。</blockquote>

		<fieldset class="layui-elem-field layui-field-title" style="margin-top: 20px;">
			<legend>添加白名单</legend>
		</fieldset>

		<div class="layui-row">
			<div class="layui-col-md8">
				<div class="grid-demo grid-demo-bg1">
					<input type="text" id="idCard" required lay-verify="required" placeholder="请输入身份证号" autocomplete="off" class="layui-input">
				</div>
			</div>
			<div class="layui-col-md4">
				<div class="grid-demo">
					<a id="jump" class="layui-btn">提交</a>
				</div>
			</div>
		</div>
		<div id="panel" style="background-color: #F2F2F2; color: #0000FF" class="layui-hide">
			<div class="layui-row layui-col-space15">
				<div class="layui-col-md8">
					<div class="layui-card">
						<div class="layui-card-body" id="result">
						</div>
					</div>
				</div>
			</div>
		</div>
	</div>
	<script>
		layui.use('layer', function(){
			$=layui.jquery;
			$(document).on('click','#jump',function(){
				const idCard = $("#idCard").val();
				$.ajax({
					type: 'POST',
					url: '/grape/user/addWhiteList',//发送请求
					data: {"idCard":idCard},
					dataType : "html",
					success: function(data) {
						$("#panel").removeClass("layui-hide");
						$("#result").text(data);
					}
				});
			});
		});

	</script>
</body>
</html>

